package com.xinzhi.savingpot.userinfo.controller;

import com.xinzhi.savingpot.userinfo.service.impl.SendCodeImpl;
import com.xinzhi.savingpot.util.BaseResponse;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/Sendcode")
@Api("发送短信")
@CrossOrigin


public class SendCdecontroller {
    @Autowired
    private SendCodeImpl sendCode;
    @PostMapping("/code")
    @ApiOperation("发送验证码")
    public BaseResponse selectcode(@RequestParam("phone") String phone){

        return sendCode.sendCode(phone);
    }

}
